home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 22
/
Aminet 22 (1997)(GTI - Schatztruhe)[!][Dec 1997].iso
/
Aminet
/
util
/
blank
/
BeyondTheDark.lha
/
BeyondTheDark
/
Developer
/
Source
/
CGraphX
/
CGraphX.c
next >
Wrap
C/C++ Source or Header
|
1997-04-20
|
1KB
|
62 lines
#include <graphics/gfxbase.h>
#include <intuition/intuition.h>
#include <utility/tagitem.h>
#include <cybergraphics/cybergraphics.h>
#define __USE_SYSBASE 42
#include <proto/cybergraphics.h>
#include <proto/exec.h>
#include <proto/graphics.h>
#include "BTD.h"
struct GfxBase *GfxBase;
struct Library *CyberGfxBase;
struct DPMSInfo CyberGraphXInfo =
{
DPMS_Revision,
"CyberGraphX","DPMS for the CyberGraphX system","Matthias Scheler",
};
/* library stuff */
char MyDPMSName[] = "cgraphx.dpms";
char MyDPMSID[] = "CGraphX DPMS V" VERSION "." REVISION " for BTD";
LONG MyDPMSLibInit(void)
{
if (GfxBase=(struct GfxBase *)OpenLibrary("graphics.library",37L))
{
if (CyberGfxBase=OpenLibrary("cybergraphics.library",40L)) return TRUE;
CloseLibrary (&GfxBase->LibNode);
}
return FALSE;
}
void MyDPMSLibFree(void)
{
CloseLibrary (CyberGfxBase);
CloseLibrary (&GfxBase->LibNode);
}
/* implementation of library functions */
struct DPMSInfo *QueryMyDPMS(void)
{
return &CyberGraphXInfo;
}
void SetMyDPMSLevel(struct Screen *Screen,ULONG Level)
{
if (IsCyberModeID(GetVPModeID(&Screen->ViewPort)))
CVideoCtrlTags (&Screen->ViewPort,SETVC_DPMSLevel,Level,TAG_DONE);
}